//
//  MedicineView.swift
//  TCMHealth
//
//  Created by Zhanyu Liu on 2023/7/13.
//

import UIKit

class MedicineView: UIView {

    @IBOutlet weak var contentview: UIView!
    var deleteCell: (() -> Void)?
    override init(frame: CGRect) {
           super.init(frame: frame)
           // 加载xib
        contentview = (Bundle.main.loadNibNamed("MedicineView", owner: self, options: nil)?.last as! UIView)
           // 设置frame
        contentview.frame = frame
           // 添加上去
           addSubview(contentview)
       }
    
    @IBAction func deleteCell(_ sender: Any) {
        deleteCell?()
    }
    required init?(coder: NSCoder) {
        fatalError("init(coder:) has not been implemented")
    }
    
//       required init?(coder aDecoder: NSCoder) {
//           fatalError("init(coder:) has not been implemented")
//       }
}
